package com.bite.config.demo.facade;
//门面模式
//通过一个方法打开或者关闭所有的灯
public class FacadeClient {

    private Light hallLight = new HallLight();
    private Light bedRoomLight = new BedRoomLight();
    private Light livingRoomLight = new LivingRoomLight();

    public void allLightOn(){
        hallLight.on();
        bedRoomLight.on();
        livingRoomLight.on();
    }

    public void allLightOff(){
        hallLight.off();
        bedRoomLight.off();
        livingRoomLight.off();
    }
}
